@ Architect - I’m sorry but I have NO clue how to set it to SPI2 for the ST7565, SSD1306 and program. ???
Look at the constructor in the driver code. It is one of the parameters that has default value set to SPI1. The example test code doesn’t provide value for that parameter, so the default is used. You just need to provide SPI2 value in your call to overwrite the default.
@ Architect - Ok on the SSD1306 and Adafruit7565 driver classes I set it to spi2
SPI.SPI_module spiModule = SPI.SPI_module.SPI2,
You can check out my onedrive.
One thing is that on the program CS is clocked at 21000khz while the 7565 is only at 10000khz.
Ok the use whatever clock value, that is right.
@ Architect - I’ll set it to 21000khz.
It says SPI MISO on 12, what lcd wire do I hook that up to?
Check my onedrive, it’s commented on program.cs.
I’m not seeing an MISO pin. Is that needed?
MISO is “Master In, Slave Out”. So this would be where the serial data comes back from the LCD to the Fez. In your case, your LCD doesn’t have one. See this post for a good explanation of the pin functions Help w/Graphic ST7565 Positive LCD (128x64) - adafruit industries
@ Brett - Thanks for clarifying!
Also something that’s ticking me off is if you check the program, it says a clock at 21000khz,
on the ssd1306 and Adafruit7565 it’s clocked at 10000khz. Is there something wrong?
let me reiterate an earlier comment I made.
Going trawling through a huge directory structure, which has lots and lots of “mini apps”, that I may or may not recognise or understand, is not a good use of my time. A good use of your time is to show us the code snippet that you’re talking about. Or even telling us EXACTLY what file we’re meant to go trawling in. If you want me to help more, you’ll have to come part way. This isn’t just a GHI forums thing, this is exactly the same as most other places online, and it shows respect of others time plus gives you more understanding of the problem yourself as you deconstruct what you’re talking about.
Now I’m assuming you’re talking about this line, in program.cs in your Adafruit7565Test app, nested several layers deep…
I have no idea what your 10000khz line is so don't know what to compare it to. This line is calling the constructor for the AdaFruit7565 class, creating an object "lcd". It happens to have a bunch of parameters being passed to it, one of those is a weird value of 21000 that I don't know where it comes from - somewhere in your Netduino helpers probably, but I am not going to unravel it to figure that out. Perhaps that's how fast the speed of the SPI channel needs to be and it's used inside the constructor. Perhaps this will work, perhaps not. You'd really need to explain what you think 10mhz and 21mhz values are, where you saw them both referenced, and what you think the hardware spec says it should be, for us to guide you. Otherwise you're relying on someone here having the same device and that's a random throw of the dice at best. But I will say, if it's the SPI speed, then the speed the SPI object is created in the constructor is critical to have matching what the actual hardware is capable of - you'd check the datasheet to find that.
@ Brett - ok then. I’ll have to check it out further.
@ Brett - So for this line, does it know that SPI2 is going to be used?
I've set things from SPI1 to SPI2 on the SSD1306 base and ST7565 drivers.
No it doesn’t. If you dig into the actual class for this LCD you’ll see what the parameters are, and SPI is not one of them. IMHO it should be a parameter. You could add that to the class with another constructor that took different parameters. You can perhaps even use VS’s auto-complete to explore the parameters - try typing out the start of this line and when you hit the AdaFruit7565 piece it’ll start showing you relevant information that you can use to see the parameter info.
(and as an aside, I’ve minimally dug into the code, I can see the 10mhz is the default value that is in the constructor for the last param… but since you provide an over-riding value, that is what is used later in the constructor).
So now, lets get down to brass tacks. What does the system do now ??? Are things working at all ?
@ Brett -
So nothing is working here still. I have not setup my backlights yet as we’re starting in a small program. Before we continue I think you all should take at least 24 hours of a break. You have given me more help than the netduino forums in a whole year. I might try get the backlights working during our rest time.
Thanks again, I do not take this for granted.
no worries mate. But let me give you a few tips/things to think about.
Go back to basics in your testing. Make sure you have a very simple test app to start with.
The backlight is a good example - have a simple test app that just toggles it and see if that works as expected.
Test LEDs or signals on a multimeter as you pulse pins. Make sure your wiring is good and makes sense from the connections you are toggling.
Try to delve into the documents that your app relies on. You might need to understand what it’s doing in relation to the way you use it, or the way you rely on it, or the results you see. (and I’m more than happy to help walk through some of that with you).
@ Brett - Holy SHIT!!!
2 people replied here! Netduino record!!!
I’ll give it a try.
@ Brett - Nope. Still nothing. I think the backlight went from white to cyan.
I think the biggest issue was the switch from atmel to ST. I’m gonna try upgrade the firmware to 4.3.
click my profile, email me. Lets see if we can Skype over the weekend and have a bit of a dig ? I might have to find a GLCD that’s similar to try to emulate.