79 subscribers
Go offline with the Player FM app!
Podcasts Worth a Listen
SPONSORED


1 Venture Investing in Mobility + Tech with University of Michigan’s Early-Stage Zell Lurie Commercialization Fund 39:30
Blue Heron: Bluetooth Low Energy (BLE) for Elixir & Nerves with Connor Rigby
Manage episode 487000256 series 2493466
Connor Rigby joins the Elixir Wizards to talk about Blue Heron BLE (Bluetooth Low Energy) support for Elixir apps. Blue Heron implements the BLE specs in pure Elixir, leveraging binary pattern matching and concurrent message processing to handle Bluetooth protocols. Unlike most solutions that require C ports or NIFs, Blue Heron runs entirely in user space, so it works seamlessly in both Nerves-based embedded projects and (eventually) desktop Elixir applications.
We discuss how Nerves development differs from building Phoenix apps. Connor shares challenges he's experienced with hardware compatibility, where some chips only partially implement the spec, and he discusses the surprisingly deep (but sometimes incomplete) world of BLE device profiles. His tip for anyone entering the BLE space: read the official spec instead of trusting secondhand blog posts. Tools like Nerves LiveBook give you hands-on examples, so you can get a BLE prototype running on a Raspberry Pi and your phone in no time.
Key topics discussed in this episode:
- Blue Heron origins and “bird” naming convention
- BLE vs. Bluetooth Classic: core differences
- Pure Elixir implementation—no C dependencies
- Binary pattern matching for packet parsing
- Hardware transport options: UART, SPI, USB, SDIO
- GenServer patterns in Nerves vs. Phoenix
- Linux requirement and power-consumption trade-offs
- GATT (Generic Attribute Table) implementation patterns
- SQLite integration for Nerves apps
- Hardware chip quirks and spec compliance
- Manufacturer-specific commands and workarounds
- BLE device profiles and spec gaps
- Security Management Profile (SMP) for encryption
- Device connection and pairing workflows
- Web vs. embedded development differences
- Where to get started: hardware recommendations and docs
Links mentioned:
https://github.com/ConnorRigby/
https://github.com/blue-heron/
https://nerves-project.org/
BLE (Bluetooth Low Energy) https://en.wikipedia.org/wiki/Bluetooth_Low_Energy
https://developer.apple.com/ibeacon/
https://learnyousomeerlang.com/building-otp-applications
Linux https://www.linux.org/
HCI (Host Controller Interface) https://en.wikipedia.org/wiki/Host_controller_interface
Circuits UART Library https://hexdocs.pm/circuits_uart/readme.html
SPI (Serial Peripheral Interface) https://github.com/elixir-circuits/circuits_spi
SDIO (Secure Digital Input Output https://en.wikipedia.org/wiki/SDIO
Raspberry Pi https://www.raspberrypi.com/
Coral SoM Dev Board https://coral.ai/products/dev-board/
BeagleBone Single-Board Linux Computer https://www.beagleboard.org/boards/beaglebone-black
https://www.bluetooth.com/bluetooth-resources/intro-to-bluetooth-gap-gatt/
Genservers https://hexdocs.pm/elixir/1.12/GenServer.html
https://hexdocs.pm/ecto/Ecto.html
https://github.com/elixir-sqlite/ecto_sqlite3
https://github.com/nerves-livebook/nerves_livebook
Special Guest: Connor Rigby.
196 episodes
Manage episode 487000256 series 2493466
Connor Rigby joins the Elixir Wizards to talk about Blue Heron BLE (Bluetooth Low Energy) support for Elixir apps. Blue Heron implements the BLE specs in pure Elixir, leveraging binary pattern matching and concurrent message processing to handle Bluetooth protocols. Unlike most solutions that require C ports or NIFs, Blue Heron runs entirely in user space, so it works seamlessly in both Nerves-based embedded projects and (eventually) desktop Elixir applications.
We discuss how Nerves development differs from building Phoenix apps. Connor shares challenges he's experienced with hardware compatibility, where some chips only partially implement the spec, and he discusses the surprisingly deep (but sometimes incomplete) world of BLE device profiles. His tip for anyone entering the BLE space: read the official spec instead of trusting secondhand blog posts. Tools like Nerves LiveBook give you hands-on examples, so you can get a BLE prototype running on a Raspberry Pi and your phone in no time.
Key topics discussed in this episode:
- Blue Heron origins and “bird” naming convention
- BLE vs. Bluetooth Classic: core differences
- Pure Elixir implementation—no C dependencies
- Binary pattern matching for packet parsing
- Hardware transport options: UART, SPI, USB, SDIO
- GenServer patterns in Nerves vs. Phoenix
- Linux requirement and power-consumption trade-offs
- GATT (Generic Attribute Table) implementation patterns
- SQLite integration for Nerves apps
- Hardware chip quirks and spec compliance
- Manufacturer-specific commands and workarounds
- BLE device profiles and spec gaps
- Security Management Profile (SMP) for encryption
- Device connection and pairing workflows
- Web vs. embedded development differences
- Where to get started: hardware recommendations and docs
Links mentioned:
https://github.com/ConnorRigby/
https://github.com/blue-heron/
https://nerves-project.org/
BLE (Bluetooth Low Energy) https://en.wikipedia.org/wiki/Bluetooth_Low_Energy
https://developer.apple.com/ibeacon/
https://learnyousomeerlang.com/building-otp-applications
Linux https://www.linux.org/
HCI (Host Controller Interface) https://en.wikipedia.org/wiki/Host_controller_interface
Circuits UART Library https://hexdocs.pm/circuits_uart/readme.html
SPI (Serial Peripheral Interface) https://github.com/elixir-circuits/circuits_spi
SDIO (Secure Digital Input Output https://en.wikipedia.org/wiki/SDIO
Raspberry Pi https://www.raspberrypi.com/
Coral SoM Dev Board https://coral.ai/products/dev-board/
BeagleBone Single-Board Linux Computer https://www.beagleboard.org/boards/beaglebone-black
https://www.bluetooth.com/bluetooth-resources/intro-to-bluetooth-gap-gatt/
Genservers https://hexdocs.pm/elixir/1.12/GenServer.html
https://hexdocs.pm/ecto/Ecto.html
https://github.com/elixir-sqlite/ecto_sqlite3
https://github.com/nerves-livebook/nerves_livebook
Special Guest: Connor Rigby.
196 episodes
All episodes
×
1 SDUI at Scale: GraphQL & Elixir at Cars.com with Zack Kayser 49:18

1 Rustler: Bridging Elixir and Rust with Sonny Scroggin 48:58

1 Nx and Machine Learning in Elixir with Sean Moriarity 44:21

1 LangChain: LLM Integration for Elixir Apps with Mark Ericksen 38:18

1 Blue Heron: Bluetooth Low Energy (BLE) for Elixir & Nerves with Connor Rigby 46:16

1 Zigler: Zig NIFs for Elixir with Isaac Yonemoto 43:00

1 Building an Open Vehicle Control System using Elixir and Nerves with Marc, Thibault, and Loïc 54:19

1 Creating Horizon: Deploy Elixir Phoenix Apps on FreeBSD with Jim Freeze 44:48

1 Telemetry & Observability for Elixir Apps at Cars.com with Zack Kayser & Ethan Gunderson 42:39

1 Scaling the Daylite Apple-Native CRM Using Elixir with AJ 52:21

1 Creating the Castmagic AI-Powered Content Workflow Platform with Justin Tormey 35:40

1 Creating the Standd AI-Native Due Diligence Platform with Stephen Solka 48:44

1 Creating the WebAuthn Components Library for Phoenix LiveView Apps with Owen Bickford 57:32

1 Creating a Terrestrial Telescope using Nerves & LiveView with Lucas Sifoni 49:56

1 Creating a Local-First Offline-Enabled LiveView PWA with Tony Dang 48:18

1 Creating VintageCell: Nerves, PCBs, and GenStateMachine with Bryan Green 28:58

1 Creating the Igniter Code Generation Framework with Zach Daniel 52:55

1 Elixir Wizards X Thinking Elixir ElixirConf 2024 Hype-isode 59:50

1 "The Past is Your Teacher" with Alicia Brindisi and Bri LaVorgna 32:56

1 "So You've Been Hired" with Emma Whamond and Micaela Cunha 46:06

1 "From Inspiration to Execution" with Camber Griffin 45:03

1 "DevOps: From Code to Cloud" with Dan Ivovich 43:43

1 "Printing is Ugly" with Joel Meador and Charles Suggs 47:03

1 "Keeping it Fresh" with Bilal Hankins and Anna Dorigo 36:00

1 "Saga of a Gnarly Report" with Owen and Dan 50:21

1 "Whose Tailwind is it Anyway?" with Ava Slivkoff 48:17


1 "Discovery Discoveries" with Alicia Brindisi and Bri LaVorgna 43:26

1 "Testing 1, 2, 3" with Joel Meador and Charles Suggs 45:40

1 Creating a Language: Elixir vs. Roc with José Valim and Richard Feldman (Elixir Wizards X Software Unscripted Podcast) 1:09:04
Welcome to Player FM!
Player FM is scanning the web for high-quality podcasts for you to enjoy right now. It's the best podcast app and works on Android, iPhone, and the web. Signup to sync subscriptions across devices.