Search found 218 matches

by rasmadrak
Mon Jul 31, 2017 12:34 am
Forum: Libraries
Topic: Troubleshooting MCP23S17 and the(?) solution.
Replies: 3
Views: 143

Re: Troubleshooting MCP23S17 and the(?) solution.

If they have a unique CS pin they have no need of a unique hardware address. The hardware address only makes any sense when you have multiple chips on a single CS pins, as in my 32-port IO expander . Yes, and that was the plan as well. But then I thought while designing the PCB, "I'll put the HW ad...
by rasmadrak
Mon Jul 24, 2017 4:05 pm
Forum: Libraries
Topic: Troubleshooting MCP23S17 and the(?) solution.
Replies: 3
Views: 143

Re: Troubleshooting MCP23S17 and the(?) solution.

Update: Reading doesn't work, it always returns 0xFFFF or 0x0000. I've also tried manually talking to the MCP's with SPI commands and it seems that HAEN never gets enabled. However, my setup is a bit peculiar though; All four chips has their own CS line and unique HW address, but utilize the same SP...
by rasmadrak
Fri Jul 21, 2017 9:57 am
Forum: Libraries
Topic: Troubleshooting MCP23S17 and the(?) solution.
Replies: 3
Views: 143

Troubleshooting MCP23S17 and the(?) solution.

So, long story short - I've designed a PCB, manufactured it and soldered on components. At the core there's a Chipkit Max32 and a bunch of other stuff, including four MCP23S17. Since there's limited information about MCP's interaction in code on the web, at least easily graspable without digging too...
by rasmadrak
Thu Jun 29, 2017 3:06 pm
Forum: Libraries
Topic: Compilation error 'panic: runtime error: index out of range'
Replies: 43
Views: 1758

Re: Compilation error 'panic: runtime error: index out of range'

Awesome!

I'll still be using UECIDE though... ;D
by rasmadrak
Tue Mar 07, 2017 9:49 am
Forum: chipKIT Boards
Topic: My first PIC32MX ISR not firing, code is hanging
Replies: 5
Views: 209

Re: My first PIC32MX ISR not firing, code is hanging

Now, we're hoping to change all of that - Just this past Saturday Microchip announced a new MPLAB X chipKIT importer plugin, so that you can suck a chipKIT sketch into MPLAB X, and program/debug it like any other C project. This will make it very very easy for anyone to try out MPLAB X and all of i...
by rasmadrak
Mon Mar 06, 2017 11:53 pm
Forum: chipKIT Boards
Topic: My first PIC32MX ISR not firing, code is hanging
Replies: 5
Views: 209

Re: My first PIC32MX ISR not firing, code is hanging

Sorry for not being more helpful, but I suspect you'd get better answers over at the MPLABX forum. :)

http://www.microchip.com/forums/Forums
by rasmadrak
Thu Feb 23, 2017 2:55 pm
Forum: chipKIT Boards
Topic: i2c with multiple devices issue
Replies: 8
Views: 412

Re: i2c with multiple devices issue

Here's one piece that might cause trouble. // Read the IO expander only if the BUTTON_INT is low //... Wire2.beginTransmission(I2C_IO_EXP_ADDR); //... while(Wire2.available()) // slave may send less than requested { c = Wire2.receive(); } if (bitRead(c,1) == 0) { Wire2.beginTransmission(I2C_IO_EXP_A...
by rasmadrak
Wed Feb 22, 2017 1:29 pm
Forum: chipKIT Boards
Topic: i2c with multiple devices issue
Replies: 8
Views: 412

Re: i2c with multiple devices issue

It sounds like there might be some sync issues that appear after a while.
Perhaps the I2C-resistor values are wrong?
by rasmadrak
Fri Feb 17, 2017 11:43 am
Forum: chipKIT Boards
Topic: i2c with multiple devices issue
Replies: 8
Views: 412

Re: i2c with multiple devices issue

Hi there,

I'm not familiar with the Wire2-library, but one thing that comes to mind:
You run beginTransmission() but vary the endTransmission variable from (1) / ().
Shouldn't this always be endTransmission()?
by rasmadrak
Mon Feb 13, 2017 11:31 pm
Forum: chipKIT Boards
Topic: USB Comm Freezes
Replies: 8
Views: 268

Re: USB Comm Freezes

I had a similar issue a while back - I had a watchdog triggered by an interrupt routine, which also handled rendering. I did a quick test to see if the watchdog worked by putting in a divide by zero in the main loop. What happened was a bit puzzling; The main loop froze in place, but rendering of th...