This shows you the differences between two versions of the page.
Both sides previous revisionPrevious revisionNext revision | Previous revision | ||
tech:rccar [2016/01/08 22:16] – [WLAN] bullar | tech:rccar [2016/01/13 21:38] (current) – [RC Car] bullar | ||
---|---|---|---|
Line 1: | Line 1: | ||
- | ===== RC Car ===== | + | ====== RC Car ====== |
- | ====STOUT==== | + | The RC-Car consists of: |
- | Connect the camera module (8-bit | + | * stout (H2 start.now) with OV10635 based camera module (8-bit I/F) |
+ | * PCB extension (RC mixer and Accel/Gyro chip) {{: | ||
+ | * 4WD drive chassis (Reely On-Road Chassis, CONRAD order no.: 238011-62) | ||
+ | * Steering servo (Modelcraft Standard-Servo 4519 Analog-Servo. CONRAD order no.: 206464 - 62) | ||
+ | * Speed controller (Modelcraft Carbon-Series Fahrtregler, | ||
+ | * LiPo 7.4V 2200mAh (for motor) | ||
+ | * LiPo 14.8V 3000mAh (for electronic) | ||
+ | * Optional: | ||
+ | * Transmitter Turnigy TGY 9X | ||
+ | * Receiver Turnigy 9X8C-V2 8-channel | ||
+ | * WLAN EDIMAX EW-7811Un | ||
+ | =====Blockdiagram===== | ||
- | ====DMESG output==== | + | {{:tech:bildschirmfoto_2016-01-13_um_22.34.59.png?direct&600|}} |
- | After boot the following messages could be find: | + | |
- | < | + | |
- | [ 2.971467] soc-camera-pdrv soc-camera-pdrv.0: Probing soc-camera-pdrv.0 | + | |
- | [ 3.094623] ov10635 2-0030: ov10635 Product ID a6 Manufacturer ID 35 | + | |
- | [ 3.734729] soc-camera-pdrv soc-camera-pdrv.1: | + | |
- | [ 3.751281] ov10635 1-0030: Failed writing register 0x0103! | + | |
- | [ 3.764290] soc-camera-pdrv soc-camera-pdrv.2: | + | |
- | [ 3.780825] ov10635 2-0031: Failed writing register 0x0103! | + | |
- | [ 3.793827] soc-camera-pdrv soc-camera-pdrv.3: | + | |
- | [ 3.810367] ov10635 1-0031: Failed writing register 0x0103! | + | |
- | [ 3.823710] rcar_jpu fe980000.jpeg-codec: | + | |
- | [ 3.842579] rcar_jpu fe980000.jpeg-codec: | + | |
- | </ | + | |
- | + | ||
- | The command '' | + | |
- | < | + | |
- | root@stout: | + | |
- | Driver Info (not using libv4l2): | + | |
- | Driver name : r8a7790-vin.0 | + | |
- | Card type : R_Car_VIN | + | |
- | Bus info : | + | |
- | Driver version: 3.10.31 | + | |
- | Capabilities | + | |
- | Video Capture | + | |
- | Streaming | + | |
- | Video input : 0 (Camera: ok) | + | |
- | Format Video Capture: | + | |
- | Width/ | + | |
- | Pixel Format | + | |
- | Field | + | |
- | Bytes per Line: 1280 | + | |
- | Size Image : 2048000 | + | |
- | Colorspace | + | |
- | Custom Info : deadbeef | + | |
- | Crop Capability Video Capture: | + | |
- | Bounds | + | |
- | Default | + | |
- | Pixel Aspect: 1/1 | + | |
- | Crop Capability Video Capture: | + | |
- | Bounds | + | |
- | Default | + | |
- | Pixel Aspect: 1/1 | + | |
- | Crop: Left 0, Top 0, Width 1280, Height 800 | + | |
- | Streaming Parameters Video Capture: | + | |
- | Capabilities | + | |
- | Frames per second: 25.000 (25/1) | + | |
- | Read buffers | + | |
- | + | ||
- | User Controls | + | |
- | + | ||
- | horizontal_flip (bool) | + | |
- | vertical_flip (bool) | + | |
- | + | ||
- | </ | + | |
- | + | ||
- | ====Capture==== | + | |
- | + | ||
- | Video can be captured with the tool '' | + | |
- | + | ||
- | **Example 1 (capture and store a MJPEG video):**\\ | + | |
- | < | + | |
- | avconv -f video4linux2 -pix_fmt yuv422p -s 1280x720 -r 25 -i /dev/video0 -c:v mjpeg result.mov | + | |
- | </ | + | |
- | + | ||
- | **Example 2 (capture and stream as H264 or MPEG2 video): | + | |
- | < | + | |
- | avconv -f video4linux2 -pix_fmt yuv422p -s 1280x720 -r 25 -i /dev/video0 -c:v libx264 -f mpegts udp:// | + | |
- | avconv -f video4linux2 -pix_fmt yuv422p -s 1280x720 -r 25 -i /dev/video0 -vcodec mpeg2video -r 25 -f rtp rtp:// | + | |
- | </ | + | |
- | + | ||
- | **Example 3 (capture one frame and store as picture): | + | |
- | < | + | |
- | ./capture -d /dev/video0 -f -o -c 1 > video_1f.uyvy | + | |
- | convert -size 1280x720 -depth 16 -sampling-factor 4:2:2 ./ | + | |
- | </ | + | |
- | + | ||
- | ** Example 4**\\ | + | |
- | + | ||
- | < | + | |
- | ./capture -d /dev/video0 -f -o -c 10000 > file.img | + | |
- | + | ||
- | gst-launch-1.0 -v v4l2src device=/ | + | |
- | + | ||
- | gst-launch-1.0 -v v4l2src device=/ | + | |
- | + | ||
- | </ | + | |
- | + | ||
- | + | ||
- | ===== WLAN ===== | + | |
- | + | ||
- | On STOUT the nano WLAN module (EW-7811Un) with Chip Set Realtek RTL818x can be embedded. | + | |
- | {{: | + | |
- | + | ||
- | The kernel has to be prepared for '' | + | |
- | + | ||
- | Load the module '' | + | |
- | '' | + | |
- | '' | + | |
- | </ | + | |
- | Where wlan0 is the name of your wireless device (this is most often the default). The above command will bring your wireless device up so it is ready to use. | + | |
- | '' | + | |
- | < | + | |
- | wlan0 Link encap: | + | |
- | UP BROADCAST MULTICAST | + | |
- | RX packets:0 errors:0 dropped:2 overruns:0 frame:0 | + | |
- | TX packets:0 errors:0 dropped:0 overruns:0 carrier:0 | + | |
- | collisions: | + | |
- | RX bytes:0 (0.0 B) TX bytes:0 (0.0 B) | + | |
- | </ | + | |
- | The next phase is to scan for any wireless access points with the command\\ | + | |
- | '' | + | |
- | From the output of the scan you should see a line (or lines) like: | + | |
- | < | + | |
- | wlan0 Scan completed : | + | |
- | Cell 01 - Address: 28: | + | |
- | ESSID:" | + | |
- | Protocol: | + | |
- | Mode: | + | |
- | Frequency: | + | |
- | Encryption key:on | + | |
- | Bit Rates:144 Mb/s | + | |
- | Extra: | + | |
- | IE: IEEE 802.11i/ | + | |
- | Group Cipher : CCMP | + | |
- | Pairwise Ciphers (1) : CCMP | + | |
- | Authentication Suites (1) : PSK | + | |
- | Quality=78/ | + | |
- | </ | + | |
- | + | ||
- | For WPA-based networks you will need to spend some effort. Do the following: | + | |
- | + | ||
- | 1. Issue the command \\ | + | |
- | '' | + | |
- | (Where SSID is your network ID and PASSWORD is your wireless password). This will generate a psk string that you will use in the configuration file. Output is: | + | |
- | < | + | |
- | network={ | + | |
- | ssid=" | + | |
- | # | + | |
- | psk=c2161655c6ba444d8df94cbbf4e9c5c4c61fc37702b9c66ed37aee1545a5a333 | + | |
- | } | + | |
- | </ | + | |
- | + | ||
- | 2. Edit the ''/ | + | |
- | + | ||
- | < | + | |
- | Network={ | + | |
- | ssid=SSID | + | |
- | psk=PSK | + | |
- | } | + | |
- | </ | + | |
- | + | ||
- | Where SSID is the actual ID of your wireless network and PSK is the string generated by the wpa_passphrase command. | + | |
- | + | ||
- | 3. Run the wpa_supplicant daemon with the command: | + | |
- | + | ||
- | '' | + | |
- | + | ||
- | Where '' | + | |
- | + | ||
- | 4. Now make sure you are associated with your network with the command \\ | + | |
- | '' | + | |
- | (Where '' | + | |
- | + | ||
- | 5. Get an IP address with the command: \\ | + | |
- | '' | + | |
- | (Where '' | + | |
- | + | ||
- | You should now be on the wireless network. | + | |
- | You can automate this by creating an entry in / | + | |
- | + | ||
- | < | + | |
- | auto wlan0 | + | |
- | + | ||
- | iface wlan0 inet dhcp | + | |
- | pre-up wpa_supplicant -Bw -Dwext -i wlan0 -c / | + | |
- | post-down killall -q pa_supplicant | + | |
- | </ | + | |
- | + | ||
- | Where INTERFACE is the name of your wireless interface. | + |