Commit graph

247 commits

Author SHA1 Message Date
chentadot
c9b05859e4 First draft for Photoresistor
the code now should setup and use the photoresistor and read it's value by the adc.
the returned value is 0 just as a place holder until the correct values are measured.
2021-09-22 22:38:30 +02:00
Yuval Aboulafia
64b2bcc6c6 simplify voltage divider 2021-09-22 22:38:30 +02:00
Yuval Aboulafia
fdd3a929da Update GERBER 2021-09-22 22:38:29 +02:00
Yuval Aboulafia
9698f3eccb minor adjustments to silkscreen 2021-09-22 22:38:29 +02:00
Yuval Aboulafia
66e1781b07 Supply V to photoresitor using nrf pin 2021-09-22 22:38:29 +02:00
Yuval Aboulafia
5fc298f57c Add Photoresistor 2021-09-22 22:38:29 +02:00
rbaron
31570f08e2
Merge pull request #14 from jhbruhn/feature/nrf52833_pin_fix
Fix pinout for fast discharge pin on E73...E
2021-09-03 19:00:47 +02:00
Jan-Henrik Bruhn
60071b5fde Fix pinout for fast discharge pin 2021-09-03 12:01:24 +02:00
rbaron
5c71363258
Merge pull request #13 from jhbruhn/feature/nrf52833
Support for E73-2G4M08S1E (nrf52833) module
2021-09-02 21:02:57 +02:00
Jan-Henrik Bruhn
05efd7474c Fix typo in code readme 2021-09-02 20:02:24 +02:00
Jan-Henrik Bruhn
683cd692ae Fix indentation and default value for PLATFORM 2021-09-02 19:46:10 +02:00
Jan-Henrik Bruhn
da049fd8ad Set optimization back to previous value 2021-09-02 15:48:46 +02:00
Jan-Henrik Bruhn
1aa07b4d74 Add platforms to readme 2021-09-02 15:45:33 +02:00
Jan-Henrik Bruhn
7c8394e709 Add support for nrf52833 based module 2021-09-02 15:40:19 +02:00
rbaron
a034827ddc Adds img/wiki/swdpins.jpg 2021-08-08 15:31:03 +02:00
rbaron
70dada1f0a Updates README.md with official ESPHome support for b-parasite
fixes #8
2021-05-31 21:41:52 +02:00
rbaron
753e5d8325 Adds the E73-2G4M08S1C module to the BOM and pick-and-place files
Note: the pick-and-place of the E73 has not been tested, since the module is currently unavailable at LCSC.
2021-05-31 21:13:00 +02:00
rbaron
795fc46849 Updates docs for data encoding in the BLE advertisement packet 2021-05-02 20:20:39 +02:00
rbaron
837a30ba03 Adds the whole MAC address in the advertisement packet 2021-05-02 12:14:52 +02:00
rbaron
19f9a68b3b Bump RTT logger buffer from 512 to 1024
It was swalloing some of the messages when debugging.
2021-05-02 11:32:45 +02:00
rbaron
dfc5a40717 Updates bridge docs 2021-05-01 18:42:58 +02:00
rbaron
c110810334 Attaches two least significant MAC address bytes to advertisement packet 2021-04-26 20:41:41 +02:00
rbaron
f0b3294f0f Fixes possible overflow in the soil moisture BLE encoding 2021-04-26 20:40:54 +02:00
rbaron
6b6bb78b6c Adds badge to README.md and renames build workflow to "firmware build" 2021-04-10 22:24:22 +02:00
rbaron
7ea4136230 Updates workflow Dockerfile to debian:bullseye-slim 2021-04-10 22:15:25 +02:00
rbaron
d518945da4 Sets up a simple lint & build CI with GitHub Actions 2021-04-10 20:56:13 +02:00
rbaron
e54449bf84 Adds make lint and make lint-fix 2021-04-10 18:19:37 +02:00
rbaron
9057d67c0c Clean up unused code and done TODO 2021-04-10 18:05:44 +02:00
rbaron
2345498ffc Adds stl and step files for a 3d printable case 2021-04-10 11:58:40 +02:00
rbaron
74977e3263 Updates Q1, Q2, Q3 orientation in kicad/parasite-top-pos.csv 2021-04-08 18:46:12 +02:00
rbaron
63d9b5127d Removes playground code 2021-04-01 14:50:28 +02:00
rbaron
3b0e2043f2 Mass cleanup 2021-04-01 14:45:35 +02:00
rbaron
463fdb5ef4 Corrects the raw ADC soil mesasure given the current input voltage 2021-03-31 20:12:47 +02:00
rbaron
d215d5f4a7 Sets transmitting power to +8dB 2021-03-31 18:37:50 +02:00
rbaron
ff97d080d7 Refactors ESPHome example 2021-03-28 10:48:25 +02:00
rbaron
3c7180fefa Adds run_counter to ble advertising packet 2021-03-28 10:44:33 +02:00
rbaron
37fd1173ec Sets MAC address to a random static value 2021-03-26 17:18:38 +01:00
rbaron
6ec48b7188 Puts soil moisture reading into the BLE advertisement packet 2021-03-26 16:30:09 +01:00
rbaron
30162f4628 Cleans up logging 2021-03-26 13:45:28 +01:00
rbaron
2aa0ffc27b Some debugging info 2021-03-26 11:43:55 +01:00
rbaron
c2e3723eb0 Adds temp and humidity values to the BLE advertisement packet 2021-03-26 10:49:28 +01:00
rbaron
81b33fbd8c Handles SHT3C sensor
...And this is the first time I'm flashing the firmware into a real
b-parasite board!
2021-03-26 10:29:54 +01:00
rbaron
25772def7e ADC works for measuring the battery voltage 2021-03-17 19:08:17 +01:00
rbaron
b521e3f0f6 A hacky fix for PWM + TWI 2021-03-15 22:40:09 +01:00
rbaron
02df5f4595 Initial shtc3 TWI/I2C implementation
Weirdly, it only works ~1/5 of the time.
2021-03-14 16:55:24 +01:00
rbaron
fb07a1244c PWM start/stop in RTC callback.
I initially tried calling prst_pwm_init() in main(), and just using start/stop in
the callback, but that led to a weird behavior in the PWM output. It was set to
high after the end of the callback.

Callnig uninit/re-calling init() inside the RTC callback fixed, but more investigation
is required.
2021-03-14 15:03:33 +01:00
rbaron
05dcb9de84 Hard coded PWM with 500kHz frequency works 2021-03-14 14:30:32 +01:00
rbaron
cf2725e028 Adds dynamic data to ble advertisement
I am very tempted to drop all the ble advertisement abstraction and deal directly with the
31-byte raw payload.
2021-03-14 11:50:26 +01:00
rbaron
20243a26a2 Extracted BLE to src/prst/ble.{c,h} 2021-03-14 11:06:45 +01:00
rbaron
a5c932def2 Extracts RTC stuff to src/rtc.{c,h} 2021-03-13 16:49:55 +01:00