[Armadeus-commitlog] armadeus branch, master, updated. latestrelease-22-gd195a5b
Brought to you by:
sszy
|
From: Julien B a. A. <ar...@us...> - 2009-07-17 15:47:00
|
This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "armadeus".
The branch, master has been updated
via d195a5b3f15db60c73f474c2129da6e31f98e9b0 (commit)
via 5122a0eeb5f6cac726b7c46bb7d6f1072d700f23 (commit)
from 38d15936f3517c556f2c20dcb55917ee098f28ea (commit)
Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.
- Log -----------------------------------------------------------------
commit d195a5b3f15db60c73f474c2129da6e31f98e9b0
Author: Julien Boibessot <jul...@ar...>
Date: Fri Jul 17 14:40:39 2009 +0200
[TEST] Put serial port in raw mode during test
commit 5122a0eeb5f6cac726b7c46bb7d6f1072d700f23
Author: Julien Boibessot <jul...@ar...>
Date: Fri Jul 17 12:10:17 2009 +0200
Applies Linux coding rules
-----------------------------------------------------------------------
Summary of changes:
target/linux/modules/max1027/max1027.c | 10 +++-------
target/test/test_rs232.sh | 9 ++++++++-
2 files changed, 11 insertions(+), 8 deletions(-)
diff --git a/target/linux/modules/max1027/max1027.c b/target/linux/modules/max1027/max1027.c
index 4fd93ae..bfdc9fb 100644
--- a/target/linux/modules/max1027/max1027.c
+++ b/target/linux/modules/max1027/max1027.c
@@ -194,13 +194,11 @@ static void max1027_send_cmd( struct spi_device *spi, u8 cmd )
}
static void max1027_start_conv(struct max1027 *max1027)
-{
-
+{
/* if no convst pin */
if (max1027->cnvst < 0) {
max1027_send_cmd(current_spi, max1027->conv_reg);
- }
- else {
+ } else {
gpio_set_value(max1027->cnvst, 0);
udelay(1);
gpio_set_value(max1027->cnvst, 1);
@@ -301,7 +299,6 @@ static void max1027_reads_async( struct spi_device *spi, int num_values )
if (ret)
printk(KERN_ERR "%s: error %i in SPI request\n",
__FUNCTION__, ret);
-
}
/*
@@ -350,11 +347,9 @@ out:
static void read_conversion_results( unsigned long data )
{
struct spi_device *spi = (struct spi_device *)data;
-
struct max1027 *max1027 = dev_get_drvdata(&spi->dev);
int size = 0;
-
/* Get conversion results from chip (depends on conversion mode) */
switch( GET_SCAN_MODE(max1027->conv_reg) )
{
@@ -401,6 +396,7 @@ static irqreturn_t max1027_interrupt(int irq, void *dev_id)
static void max1027_flush_all_channels(struct max1027 *p_max1027)
{
int i;
+
for (i=0; i < NB_CHANNELS; i++) {
if( p_max1027->channels[i] != NULL )
fifo_flush(p_max1027->channels[i]);
diff --git a/target/test/test_rs232.sh b/target/test/test_rs232.sh
index 4d58858..79a7f7b 100755
--- a/target/test/test_rs232.sh
+++ b/target/test/test_rs232.sh
@@ -37,12 +37,19 @@ test_serial_port()
echo -n "Connect loopback jumper"
execute_for_target echo_jumper_help_apf9328 echo_jumper_help_apf27
ask_user "and then press <ENTER>"
+ # Configure port as raw
+ stty -F $SERIAL_DEVICE raw
+ stty -F $SERIAL_DEVICE -echo -echoe -echok
+ # Get incoming data
cat $SERIAL_DEVICE > $TEMP_FILE &
pid=$!
echo -n "."; sleep 1
- echo "Serial Port N°$1 is working !" > $SERIAL_DEVICE
+ # Send data
+ echo "Serial Port N°$1 ($SERIAL_DEVICE) is working !!!!!!!!!!" > $SERIAL_DEVICE
echo -n "."; sleep 1; echo
+ cat /proc/interrupts | grep uart
kill $pid
+ # Check if data were transmitted
grep "working" $TEMP_FILE
if [ "$?" == 0 ]; then
echo_test_ok
hooks/post-receive
--
armadeus
|