Reading DHT22 and Light sensor data using NodeMCU dev board

Experimented with reading DHT22 amd Light sensor modules using NodeMCU ESP12E development board. Main problem I had that timer did not work on old firmware, had to update it ( read previous post ). Other that that all went fine and could read data.One strange thing is that I am getting temperature a little bit higher than actual. Not sure why is that, maybe because board is powered by 3.3v and not 5v. Will have to find out that later.Code:if not tmr.alarm(0, 5000, tmr.ALARM_AUTO , function() print("Starting to read data:") light = adc.read(0) or "" print("Light:"..light) pin = 4 status, temp, humi, temp_dec, humi_dec = dht.readxx(pin) if status == dht.OK then -- Float firmware using this example print("DHT Temperature:"..temp..";".."Humidity:"..humi) elseif status == dht.ERROR_CHECKSUM then print( "DHT Checksum error." ) elseif status == dht.ERROR_TIMEOUT then print( "DHT timed out." ) end end) then print("whoopsie") end

0 Comments

tmr.alarm not working on ESP12E 0.9.5 firmware

Tested that this sample was not working on dev board:if not tmr.alarm(0, 5000, tmr.ALARM_SINGLE, function() print("hey there") end) then print("whoopsie") endChecked firmware version (connected to ESPlorer and pressed reset):ESP12E default NodeMCU 0.9.5 build 20150318  powered by Lua 5.1.4Decided to update firmware. Found here that only 9.6 is available precompiled, later ones have to be costum built. Downloaded 9.6 files and uploaded them using ESP8266Flasher.exeChecked firmware version then:NodeMCU 0.9.6 build 20150704  powered by Lua 5.1.4And tested this code sample:if not tmr.alarm(0, 5000, tmr.ALARM_SINGLE, function() print("hey there") end) then print("whoopsie") endIt worked.

0 Comments

How to use Arduino IDE to program NodeMCU

1. Install the Arduino IDE from download section of arduino.cc website 2. Run Arduino IDE's arduino.exe3. Arduino IDE >> File >> Preferences (Shourtcut is CTRL + COMMA)>> Settings tab >> on Additional Board Manager URL side type this >> and click ok.http://arduino.esp8266.com/stable/package_esp8266com_index.jsonThis json object will bring necessary drivers for NodeMCU from the website esp8266.com to our Arduino IDE.4. Arduino IDE >> Tools >> Board >> Boards Manager... >> Type = Contributed >> click on install (Or, search ESP8266 from the search bar)5. Arduino IDE >> Tools >> Board >> NodeMCU 1.0 (ESP-12E MODULE)

0 Comments

Repairing ZX Spectrum Kempston joystick

As recently I started tinkering with ZX Spectrum hardware, tested one old joystick I had. Up and right positions did not work during the games. Tested port reading with one simple program:10 LET x=IN 3120 PRINT X30 GOTO 10There was no reading in up and right position.I took apart joystick case and tested connection between PCB and plug - there was no connection for up and right wires.So, just took now DB9 female connector and soldered it instead of an old one that I have just cut away. 

0 Comments

Fixing ZX Spectrum+ 48K (s/n S01-135100) video problems

So, this ZX spectrum was alive, but during testing with some games (for example game "Breakthrough"), I noticed strange video glitch in upper screen part:My guess was it is not video RAM related, but probably RF module fault. First decided to change all electrolytic caps on the board and see if it helps - it did not. Picture was the same.Then decided to check RF module - remove it and re solder all joints.After putting it back I did a check with the same game. It helped a bit, but still I was not happy with the result. White line disappeared, but it seemed like upper part was washed away a bit:And then it came to my mind a thought about why the hell I am using this RF module at all. I could just do a composite mod and that would definitely would solve all RF related video problems.Composite mod as it is called, is just disconnecting power and signal wires that go from RF module - means disconnecting RF module. Then, in the RF module itself, disconnecting resistor from video output connector. And finally, connecting video output from board to video output connector in RF module using…

0 Comments

Another ZX Spectrum 48K

Maybe I got carried away.. but here is another non working rubber keyboard ZX Spectrum I got (s/n D01-257600).Its interesting regarding those serial numbers, some are 01 some D01. I really would like to know what do they mean, if they mean anything ? Found one site that has list of some serial numbers and has a form to submit more. Probably later I will submit them serial number of my ZX Spectrum machines. But now, back to this one.. On the outside it has some bruises and scratches, also it has lost all of its rubber pads, but inside looks good.Actually it looked so good that I powered it immediately and saw nice working home screen. But after pressing some keys found than none of them work. No wonder why because when opened the box immediately found reason.Keyboard membrane connector was cracked near the connector and was totally broken near the membrane, So, it seems that now I am looking after replacement membrane,To be continued.

0 Comments

Repairing ZX Spectrum+ 48K

Another was ZX Spectrum+ 48K (s/n S01-135100). After turning it on could not see clear image (sorry did not take image of that picture). When I disassembled this device I found that it already had some changes, lower RAM chips were not original, it had some jumper wires soldered on PCB, transistor TR4 seemed like already replaced (at least someone did some soldering with it). Expecting the worst I started to check voltages (using this guide) and noticed that 12V is missing on lower RAM chips. When checked transistors TR5 and TR4 found that TR4 is most probably faulty. TR4 is ZTX650 and I started searching replacements for it. Somewhere in a forums I fount that:TR4 ZTX650 can be replaced with 2SD1207.TR5 ZTX 213 can be replaced with 2SA733 ( or BC212, BC257, BC307, BC557).I could easily find 2SD1207 and replace it. Just one important thing - pins of ZTX650 and 2SD1207 are different:But good thing is that it was already overlooked by ZX Spectrum PCB designers and it had holes for alternative pinout transistor near the original one ( see photo ).Voltages immediately changed to correct ones. After powering it up it started nicely. Whoohoo, it was an easy fix.*One interesting thing is that on the back of ZX Spectrum case there was a sticker with text: 31.7.86 RR…

0 Comments

Repairing and upgrading ZX Spectrum 16K

Going back into retro computing. Recently got little bit nostalgic and purchased two used non working ZX Spectrum machines. One was 16K, SN 001-201230.Tested some voltages using this guide and it seemed like everything is more ore less normal. Plugged it to TV antenna, tuned to channel 35, turned it on and as expected it didn't work. As usual biggest suspects were 4116 lower RAM chips:I had two options, first was to cut those IC`s out and desolder leads that were left using regular soldering iron. But doing that I would destroy those chips and I had a feeling that only some of them are not working and I could use others later. So, I bought cheap desoldering pump with a heater and spent some time desoldering those eight 4116 RAM chips. Actually, before that I have never used such desoldering pump and now I can say it does magic and I cannot imagine how I did all my electronics tinkering before without it.Then I just took eight 16 DIP sockets and soldered them in places where those IC`s were:Next thing was to find something to replace 4116 chips. I could not found 4116 somewhere around and buying them online takes…

0 Comments

End of content

No more pages to load