-
-
As I learn about Espruino, I'm trying out a lot of different stuff. This board with a color TFT, touch-screen display was listed in the "unoffical" boards, I got one at a steal, and it arrived today.
HY-MiniSTM32V Dev Board + 3.2" TFT LCD Module
So, how do I flash it? I have no idea where to start.
Also, are there modules already available to drive and sense the display?
Also, it has a kind of nifty demo already flashed on it... is there some way to dump this so I can flash it back later if I want to?
-
Well well well... I just bothered to quickly review the STM32 datasheet, and see that there is a full-blown CAN state machine built in, functionality very similar to the MCP2515 above. I now understand Gordon's comments in this thread better.
So... abandoning the MCP2515 for the first go-around; I'm going to try and use the built-in CAN controller, configured on two of the GPIO pins on my Pico. I hope to succeed and be able to contribute a CAN module to the community here.
-
I've determined with certainty it's a flaky board (what do you expect for $7?).
If I have contact with the area of the board where the CP2102 USB/serial chip is (but not just contact with that IC), it runs fine. As soon as I take my hand away, it get's stuck somehow and the WDT fires.
I can even carefully take the board on the end of the USB cable and carefully put it under my shirt against my stomach, carefully remove my thumb from the "magic" area, and then use both hands to interact with it in the IDE. Pull it away from my body, same crash.
So, it's capacitive coupling of some sort due to seven dollar manufacturing. Got a few more ESP12E variants on the way, as well as a dozen raw 12E SMD boards (couldn't pass up $1.50 each w/free shipping on eBay), so I'll confirm shortly that it's what I think it is.
Until then, I have my Pico to work with, solid as a rock.
-
Well. Three year old thread. Did anything ever happen with this?
Here's why: CAN bus communication is part of my bigger project (which involves WS2812B lightstrip control as well, as some of you know from my other postings).
I got one of these on Amazon, 8 bucks:
CHENBO(TM) Smart Electronics MCP2515 CAN Bus Module TJA1050 Receiver SPI
I've been studying the datasheet for MCP2515, and there is an Arduino library for accessing this chip to reference. So, if no one else has implemented anything with the MCP2515 to interface with CAN, I guess I'll be contributing a module to the community soon...
If there is already code out there, a pointer would be greatly appreciated!
@Gordon: Much more than just OBDII (diagnostics). Virtually everything that happens in a modern car is sensed and controlled via messaging over CAN and LIN digital master/slave buses. Once on the CAN bus, it's possible to have an Espruino do all sorts of neat things. Controlling windows; entertainment; lighting; and on and on. Access to every parameter the car either senses or synthesizes.
-
@Ollie thanks for the suggestion -- unfortunately, that's what I did every time I flashed it, so that's not the problem. I'll give it another go, though, and see what happens.
-
Do not understand what you mean about the I2C code and saving. I'm a noob :-)
However, it doesn't matter -- I get this problem with a virgin, freshly flashed NodeMCU esp8266. I had a problem at first that I'd flashed for the 512kb 01 board, but fixed that and am still getting this watchdog timer issue with nothing loaded and running at all.
Oh, and the strangest part of this -- it acts like noise or some capacitive coupling issue because if I rest my finger on the board in the right place (among other things, the CP2102 chip is there -- USB->serial) the problem doesn't happen.
-
With the help of fellow travelers here, I got my WS2811 50LED test strip working using the neoPixel call. I was unsuccessful using SPI directly through GPIO13 (NodeMCU D7) with the exact same code that works like a champ on the Pico. I followed the example in the tutorial using the send4bit call to shape the NZR waveform the 2811B modules are expecting.
Got some light, but weird colors, not what I sent. I'm guessing the baud rate setting is not precise, or, as Gordon mentioned in another thread, the H/W SPI still does some waiting/checking/something for each byte, so the continuous 800khz stream isn't actually happening. (Aside, where can I find the source for the neopixelWrite() call? I'd like to see how its implemented).
Anyway, my main problem's solved: I can drive these strips effectively with an 8266, which was the goal.
Here's the problem: I get these random crashes:
_____ _ | __|___ ___ ___ _ _|_|___ ___ | __|_ -| . | _| | | | | . | |_____|___| _|_| |___|_|_|_|___| |_| http://espruino.com 1v85.tve_master_66fde09 Copyright 2016 G.Williams Espruino is Open Source. Our work is supported only by sales of official boards and donations: http://espruino.com/Donate Flash map 4MB:512/512, manuf 0xe0 chip 0x4016 > ets Jan 8 2013,rst cause:4, boot mode:(3,7) wdt reset load 0x40100000, len 1396, room 16 tail 4 chksum 0x89 load 0x3ffe8000, len 776, room 4 tail 4 chksum 0xe8 load 0x3ffe8308, len 540, room 4 tail 8 chksum 0xc0 csum 0xc0 2nd boot version : 1.4(b1) SPI Speed : 80MHz SPI Mode : QIO SPI Flash Size & Map: 32Mbit(512KB+512KB) jump to run user1 @ 1000 r Disconnected
What's going on? Looks like a reset -- is that a flaky reset button on the NodeMCU board? I note that if I rest my finger over the button area, contacting the USB connector, and over some other components on the board, the problem goes away. So it looks like noise. However, I don't know how to interpret "rst cause:4" and the other stuff sent to the console.
-
-
I was having similar, interesting problems with a HiLetgo NodeMCU board, and found it was a poor ground near the micro USB connector, such that if I just rested my fingertip there I could connect successfully (115200 baud), get a prompt, and interact normally with the board after removing my finger. It seems to be only on initial connection that there's this noise flakiness.
After getting in, I set up connecting the console via wifi (telnet), and connect that way without issue.
-
I DID try searching first, and came up with nothing.
Are the SPI pins supported? HSPI? Is the latter "hardware" SPI? But aren't the SPI pins also hardware controlled/managed? Surely not bit-banged?
Supported through the core SPI object? If so, what's the built-in var?
Sorry for the rapid-fire questions, I'm a little frustrated 'cause I can't piece it together from what I can find on the forum. Forgive my crankiness :-)
-
-
Be careful about power... I2R losses on WS2812B 5050SMD light strips drop in voltage enough to screw the logic chip in the module after about 100-150 lights. This will manifest in odd behavior of the lights on the tail end. In particular, if you try setting and entire 300LED 5meter reel to full on white GRB=[255,255,255] you'll see soli white for about 100, then it will start to turn a warmer color as you get further down the strip, until completely off at about count 130 (these numbers are eyeballed approximations).
Actual animated color control will see odd behavior in the tail end of the light chain, depending on how bright you're setting things.
Bottom line: you need to bring power out and splice it in about every 100 or so lights.
-
This is an ESP8266 board with wifi. Bought one from Amazon for US$8.79, free shipping on Amazon Prime. For that price, it was worth getting one just to see what I can do with it.
Has anyone loaded the Espruino ESP8266 build on this board? If so, any pointers (or link to a thread)?
If not, any advice for me in getting Espruino firmware running on the board? Just came in yesterday, so I'm playing with it today, trying to get it working.
If I can get it going, I plan to take an existing wifi driver and hack it to get it working with the wifi module on this board (again, if no one has already done it).
-
Thanks Gordon! The HC-05/06 sounds like an ideal solution. I have lots of experience developing Android apps, and my "vision" was to be able to control directly from my phone. This will work quite well. On my way to order a module...
I haven't done any BT development, however, so I'm new to all the code "help" available to do things like transfer data, etc. Is there a stack/library/layer available that simplified IPC across BT in a robust way? I'd rather not create my own protocol to run over a serial BT connection to reliably transfer data, messages, etc.
-
Played with it a bit more and, at least in my case, it's definitely some static sensitivity. If I rest my finger on the button, then it takes a positive, tactile-feedback press -- every time -- to activate the button.
If I simply bring my finger over to to the board at random time to "press" the button, it will activate often at my finger just touches, without any force, the top of the button.
-
I see similar "sensitive" behavior with the button on my pico, and just assumed it was a defective button. Since i don't really use it, it's not an issue.
However, same thing: Seems sometimes I just need to get my finger near the button for it to activate. Odd, since the expected tactile "snap" of the button when you actually press it is there. Yet, it seems to take just the lightest of contact -- no actual push -- to activate it.
This is on the canned demo LED lighting watch that is preloaded with the IDE.
-
First, big props Gordon for a fantastic idea and product!
I'm just starting out on a project to add accent lighting in my car. I'm using WS2812B RGB light strips. The tutorial on the programming a similar LED lightstring was extremely helpful.
I will have several picos in the car, not easily accessible when everything's buttoned up and the trim is all put back. I'd like to be able to connect to any of them wirelessly and ideally interact with my laptop right in the IDE as if it was connected with a USB cable... is this possible with either the BT or wifi modules?
Also, what sort of IPC is available over bluetooth? I'd love to be able to easily hack up some app on my Android phone to control the things in addition to the LIN bus traffic I will be monitoring to set colors, intensity, etc.
Heck, the best way to do this would be to put a single pico on the LIN bus to sniff, then control the lighting via wireless talking to them.
Any/all advice and pointers to help me get the wireless part of this figured out is greatly appreciated!
Good points, and I didn't consider that the Pico has an M4. Also, I do have the Chenbo board, which has the line drivers on it already so can wire right in to the bus in my car. Changing my mind again :-)
re
Re: ELM323 -- ah, got ya now. I need to do this anyway for the lighting project I'm working on, so I've got to bite the bullet.